﻿using mds.BaseFrameModel;
using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceModel;
using System.Text;

namespace mds.CMSService
{
    [ServiceContract(Namespace = "mds.CMSService.CMSProvider")]
    public interface ICMSProvider
    {
        [OperationContract(Name = "ParseOutput")]
        OperationResult<String> ParseOutput(Dictionary<string, string> contentData, string template);
        [OperationContract(Name = "GetTemplatePageList")]
        List<PageTemplate> GetTemplatePageList(int currentPage, int pageSize, string searchKey, out int total);
        [OperationContract(Name = "GetTemplateById")]
        string GetTemplateById(int templateId);
        /// <summary>
        /// 操作成功返回信息id，失败返回0
        /// </summary>
        /// <param name="pageTemplateId"></param>
        /// <param name="templateName"></param>
        /// <param name="templateContent"></param>
        /// <param name="createBy"></param>
        /// <param name="modifyBy"></param>
        /// <returns>信息id</returns>
        [OperationContract(Name = "PageTemplateUpdate")]
        int PageTemplateUpdate(int pageTemplateId, string templateName, string templateContent, int templateType, int createBy, int modifyBy);
        [OperationContract(Name = "DeleteInfos")]
        bool DeleteInfos(int[] templateIds, int operationBy);
    }
}
